package day03.note;

import java.util.Scanner;

public class txt16 {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        int num=sc.nextInt();
        int i=1;//阶乘
        int result=1;//结果
        while (i<=num){
            result=result*i;
            i++;
        }
        System.out.println(result);
        }
    }

